using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration;using Maxleaf.EDI.Domain.K3;

namespace Maxleaf.EDI.DataAccess.K3
{
    public class t_ICTeamTimeEntryMap : EntityTypeConfiguration<t_ICTeamTimeEntry>
    {
        public t_ICTeamTimeEntryMap()
        {
            // Primary Key
            this.HasKey(t => t.FEntryID);

            // Properties
            this.Property(t => t.FClass)
                .IsRequired()
                .HasMaxLength(300);

            this.Property(t => t.FBeginTime)
                .HasMaxLength(50);

            this.Property(t => t.FEndTime)
                .HasMaxLength(50);

            this.Property(t => t.FNote)
                .IsRequired()
                .HasMaxLength(300);

            // Table & Column Mappings
            this.ToTable("t_ICTeamTimeEntry");
            this.Property(t => t.FEntryID).HasColumnName("FEntryID");
            this.Property(t => t.FID).HasColumnName("FID");
            this.Property(t => t.FIndex).HasColumnName("FIndex");
            this.Property(t => t.FClass).HasColumnName("FClass");
            this.Property(t => t.FBeginHour).HasColumnName("FBeginHour");
            this.Property(t => t.FBeginMinute).HasColumnName("FBeginMinute");
            this.Property(t => t.FBeginTime).HasColumnName("FBeginTime");
            this.Property(t => t.FEndHour).HasColumnName("FEndHour");
            this.Property(t => t.FEndMinute).HasColumnName("FEndMinute");
            this.Property(t => t.FEndTime).HasColumnName("FEndTime");
            this.Property(t => t.FHours).HasColumnName("FHours");
            this.Property(t => t.FNote).HasColumnName("FNote");
        }
    }
}
